<ng-form name="vm.categoryAccessControlForm">
<vertical-section-layout allow-edit="vm.allowEdit && !vm.isNew" section-title='{{"views.category-access-control.AC" | translate}}' on-save-edit="vm.onSave()" on-edit="vm.onEdit()" keep-editable-after-save="true" editable="vm.isEditable" is-valid="vm.isValid">
  <readonly-section>
    <div>{{"views.category-access-control.CR" | translate}}</div>
    <entity-access-control entity="vm.model" entity-type="category" the-form="vm.categoryAccessControlForm" read-only="true"></entity-access-control>
    <div>{{"views.category-access-control.RIbF" | translate}}</div>
    <entity-access-control entity="vm.model" entity-type="category-feed" allow-owner-change="false" role-memberships-property="feedRoleMemberships" the-form="vm.categoryAccessControlForm" read-only="true"></entity-access-control>
    <div>Index Control</div>
    <div layout="row" layout-padding>
      <div flex="40" style="align-self:center;">
        <span>Index category metadata</span>
        <div class="hint">
          Index metadata for the category in a search engine.
        </div>
      </div>
      <div flex class="">
        <md-checkbox
            ng-model="vm.model.allowIndexing"
            aria-label="Indexing Allowed"
            ng-true-value=true
            ng-false-value=false
            ng-disabled="true"
            class="md-primary md-align-top-left" flex>
        </md-checkbox>
      </div>
    </div>

  </readonly-section>
  <editable-section>
    <div>{{"views.category-access-control.CR2" | translate}}</div>
    <entity-access-control entity="vm.editModel" entity-type="category" the-form="vm.categoryAccessControlForm"></entity-access-control>
    <div>{{"views.category-access-control.RIbF2" | translate}}</div>
    <entity-access-control entity="vm.editModel" entity-type="category-feed" allow-owner-change="false" role-memberships-property="feedRoleMemberships" the-form="vm.categoryAccessControlForm"></entity-access-control>
    <div>Index Control</div>
    <div layout="row" layout-padding>
      <div flex="40" style="align-self:center;">
        <span>Index category metadata</span>
        <div class="hint">
          Index metadata for the category in a search engine. (Unchecking will disable indexing of category's metadata, and also delete the category's existing metadata from index.)
        </div>
      </div>
      <div flex class="">
        <md-checkbox
            ng-model="vm.editModel.allowIndexing"
            aria-label="Indexing Allowed"
            ng-true-value=true
            ng-false-value=false
            ng-disabled="false"
            class="md-primary md-align-top-left" flex>
        </md-checkbox>
      </div>
    </div>
  </editable-section>
</vertical-section-layout>
</ng-form>
